ccR.Rotation = {
	Run = 
	function()
		local rotation = ccR.Var("Rotation")
		if rotation == nil then ccR.Error("No rotation chosen") ccR.Rotation.Stop() return end
		if _G[rotation] ~= nil 
		then 
			if ccR.Var("Use_Auto_Face")
			and (not ccR.Var("Auot_Face_InCombatOnly") or (ccR.Var("Auot_Face_InCombatOnly") and ccR.Player.Is.In.Combat()))
			and ccR.Target.Exists()
			then
				ccR.Auto.Face() 
			end
			if ccR.Var("Use_Auto_Target") then ccR.Auto.Target() end
			ccR.Use.Racials()
			ccR.Use.Trinkets()
			_G[rotation]() 
		else
			ccR.Error(tostring(rotation) .. "() is not found.") ccR.Rotation.Stop() return 
		end
	end,
	Start =
	function()
		if ccR.Sys.FireHack()
		and ccR.Sys.Valid(ccR.Var("Rotation")) 
		then
			if not ccR.Var("Toggle") then
				ccR.Var("Toggle", true)
				if not ccR.Var("Hide_Toggle") then ccR.Sys.PrintToChat("Enabled") end
				ccR.Sys.CactuaR.Toggle("on")
			end
		end
	end,
	Stop = 
	function()
		if ccR.Var("Toggle") then
			ccR.Var("Toggle", false)
			if not ccR.Var("Hide_Toggle") then ccR.Sys.PrintToChat("Disabled") end
			ccR.Sys.CactuaR.Toggle("off") 
		end
	end,
	Toggle = 
	function()
		if ccR.Var("Toggle") then
			ccR.Rotation.Stop()
		else
			ccR.Rotation.Start()
		end
	end,
}
setmetatable(ccR.Rotation, ccR)